unit scheduler;

interface

uses classes, extctrls;

type tproc = tnotifyevent;

type Tscheduler = class
    x: array of ttimer;
    procedure add(interval: integer; proc: tproc);
  end;

implementation

{ Tscheduler }

procedure Tscheduler.add(interval: integer; proc: tproc);
var act: integer;
begin
  act := length(x);
  setlength(x, act + 1);
  x[act] := ttimer.Create(nil);
  x[act].OnTimer := proc;
  x[act].Enabled := true;
end;


end.

